package array.others;

import java.util.Arrays;

public class N1619_MeanOfArrayAfterRemovingSomeElements {
    public double trimMean(int[] arr) {
        int n = arr.length;
        Arrays.sort(arr);
        int sum = 0;
        for (int i = n / 20; i < 19 * n / 20; i++) {
            sum += arr[i];
        }
        return sum / (0.9 * n);
    }
}
